import http from '@/utils/http'

//分页查询
export function pageList(data) {
    return http.post('/api/ingredient/pageList', data)
}

//新增
export function add(data) {
    return http.post('/api/ingredient/add', data)
}

//修改
export function edit(data) {
    return http.post('/api/ingredient/edit', data)
}

//详情
export function findDetail(data) {
    return http.post(`/api/ingredient/findDetail/${data}`)
}

//删除
export function deleteIngredient(data) {
    return http.post(`/api/ingredient/delete/${data}`)
}

//查询不同类别对应食材列表
export function findIngredientWithCategory() {
    return http.post(`/api/ingredient/findIngredientWithCategory`)
}
